// @ts-ignore
/* eslint-disable */
import request from '@/request'

/** 此处后端没有提供注释 POST /chat/add */
export async function addLearnChat(
  body: API.LearnChatAddRequest,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseLong>('/chat/add', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 GET /chat/chat/model/learn */
export async function chatToLearn(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.chatToLearnParams,
  options?: { [key: string]: any }
) {
  return request<API.ServerSentEventString[]>('/chat/chat/model/learn', {
    method: 'GET',
    params: {
      // model has a default value: qwen-turbo
      model: 'qwen-turbo',
      // promptId has a default value: 0
      promptId: '0',
      ...params,
    },
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 GET /chat/deep-thinking/chat/model/learn */
export async function deepThinkingChatToLearn(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.deepThinkingChatToLearnParams,
  options?: { [key: string]: any }
) {
  return request<API.ServerSentEventString[]>('/chat/deep-thinking/chat/model/learn', {
    method: 'GET',
    params: {
      // model has a default value: qwen-turbo
      model: 'qwen-turbo',
      // promptId has a default value: 0
      promptId: '0',
      ...params,
    },
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 POST /chat/delete */
export async function deleteLearnChat(body: API.DeleteRequest, options?: { [key: string]: any }) {
  return request<API.BaseResponseBoolean>('/chat/delete', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 GET /chat/enhance/prompt */
export async function enhanceTheUserPrompt(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.enhanceTheUserPromptParams,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseString>('/chat/enhance/prompt', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 GET /chat/list/model */
export async function listModel(options?: { [key: string]: any }) {
  return request<API.BaseResponseListModelView>('/chat/list/model', {
    method: 'GET',
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 POST /chat/my/list/page/vo */
export async function listMyLearnChatVoByPage(
  body: API.LearnChatQueryRequest,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponsePageLearnChat>('/chat/my/list/page/vo', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** 此处后端没有提供注释 POST /chat/update */
export async function updateLearnChat(
  body: API.LearnChatUpdateRequest,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean>('/chat/update', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}
